home *** CD-ROM | disk | FTP | other *** search
/ IRIX Base Documentation 1998 November / IRIX 6.5.2 Base Documentation November 1998.img / usr / share / catman / p_man / cat2 / standard / sigset.z / sigset
Text File  |  1998-10-20  |  8KB  |  133 lines

  1.  
  2.  
  3.  
  4. SSSSIIIIGGGGSSSSEEEETTTT((((2222))))                                                            SSSSIIIIGGGGSSSSEEEETTTT((((2222))))
  5.  
  6.  
  7.  
  8. NNNNAAAAMMMMEEEE
  9.      sigset, sighold, sigrelse, sigignore, sigpause - signal management
  10.      (System V)
  11.  
  12. CCCC SSSSYYYYNNNNOOOOPPPPSSSSIIIISSSS
  13.      ####iiiinnnncccclllluuuuddddeeee <<<<ssssiiiiggggnnnnaaaallll....hhhh>>>>
  14.  
  15.      _CCCC_::::
  16.        vvvvooooiiiidddd ((((****ssssiiiiggggsssseeeetttt ((((iiiinnnntttt ssssiiiigggg,,,, vvvvooooiiiidddd ((((****ddddiiiisssspppp))))(((())))))))))))(((())));;;;
  17.      _CCCC_++++_++++_::::
  18.        vvvvooooiiiidddd ((((****ssssiiiiggggsssseeeetttt ((((iiiinnnntttt ssssiiiigggg,,,, vvvvooooiiiidddd ((((****ddddiiiisssspppp))))((((iiiinnnntttt))))))))))))((((iiiinnnntttt))));;;;
  19.  
  20.      _####_iiii_ffff ______XXXX_OOOO_PPPP_EEEE_NNNN______SSSS_OOOO_UUUU_RRRR_CCCC_EEEE
  21.        vvvvooooiiiidddd ((((****ssssiiiiggggsssseeeetttt ((((iiiinnnntttt ssssiiiigggg,,,, vvvvooooiiiidddd ((((****ddddiiiisssspppp))))((((iiiinnnntttt))))))))))))((((iiiinnnntttt))));;;;
  22.      _####_eeee_nnnn_dddd_iiii_ffff
  23.  
  24.      iiiinnnntttt ssssiiiigggghhhhoooolllldddd ((((iiiinnnntttt ssssiiiigggg))));;;;
  25.  
  26.      iiiinnnntttt ssssiiiiggggrrrreeeellllsssseeee ((((iiiinnnntttt ssssiiiigggg))));;;;
  27.  
  28.      iiiinnnntttt ssssiiiiggggiiiiggggnnnnoooorrrreeee ((((iiiinnnntttt ssssiiiigggg))));;;;
  29.  
  30.      iiiinnnntttt ssssiiiiggggppppaaaauuuusssseeee ((((iiiinnnntttt ssssiiiigggg))));;;;
  31.  
  32. DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN
  33.      These functions provide signal management for application processes.
  34.      _ssss_iiii_gggg_ssss_eeee_tttt specifies the system signal action to be taken upon receipt of
  35.      signal _s_i_g.  _d_i_s_p specifies the signal's disposition, which may be
  36.      _SSSS_IIII_GGGG______DDDD_FFFF_LLLL, _SSSS_IIII_GGGG______IIII_GGGG_NNNN, or the address of a signal handler.  If _d_i_s_p is the
  37.      address of a signal handler, the system adds _s_i_g to the calling process's
  38.      signal mask before executing the signal handler; when the signal handler
  39.      returns, the system restores the calling process's signal mask to its
  40.      state prior to the delivery of the signal.  In addition, if _d_i_s_p is equal
  41.      to _SSSS_IIII_GGGG______HHHH_OOOO_LLLL_DDDD, _s_i_g is added to the calling process's signal mask and the
  42.      signal's disposition remains unchanged.  If _d_i_s_p is not equal to
  43.      _SSSS_IIII_GGGG______HHHH_OOOO_LLLL_DDDD, _s_i_g will be removed from the calling process's signal mask
  44.      (this behavior is different than _ssss_iiii_gggg_aaaa_cccc_tttt_iiii_oooo_nnnn(2)).
  45.  
  46.      _ssss_iiii_gggg_hhhh_oooo_llll_dddd adds _s_i_g to the calling process's signal mask.
  47.  
  48.      _ssss_iiii_gggg_rrrr_eeee_llll_ssss_eeee removes _s_i_g from the calling process's signal mask.
  49.  
  50.      _ssss_iiii_gggg_iiii_gggg_nnnn_oooo_rrrr_eeee sets the disposition for _s_i_g to _SSSS_IIII_GGGG______IIII_GGGG_NNNN.
  51.  
  52.      _ssss_iiii_gggg_pppp_aaaa_uuuu_ssss_eeee removes _s_i_g from the calling process's signal mask and suspends
  53.      the calling process until a signal is received.  This system call is
  54.      useful for testing variables that are changed on the occurrence of a
  55.      signal.  The correct usage is to use _ssss_iiii_gggg_hhhh_oooo_llll_dddd to block the signal first,
  56.      then test the variables.  If they have not changed, then call _ssss_iiii_gggg_pppp_aaaa_uuuu_ssss_eeee to
  57.      wait for the signal.
  58.  
  59.  
  60.  
  61.  
  62.  
  63.                                                                         PPPPaaaaggggeeee 1111
  64.  
  65.  
  66.  
  67.  
  68.  
  69.  
  70. SSSSIIIIGGGGSSSSEEEETTTT((((2222))))                                                            SSSSIIIIGGGGSSSSEEEETTTT((((2222))))
  71.  
  72.  
  73.  
  74.      For a list of valid signal numbers and a general description of the
  75.      signal mechanism, please see _ssss_iiii_gggg_nnnn_aaaa_llll(5).
  76.  
  77.      These functions will fail if one or more of the following are true:
  78.  
  79.      [EINVAL]  _s_i_g is an illegal signal number (including _SSSS_IIII_GGGG_KKKK_IIII_LLLL_LLLL and _SSSS_IIII_GGGG_SSSS_TTTT_OOOO_PPPP)
  80.                or the default handling of _s_i_g cannot be changed.
  81.  
  82.      [EINVAL]  The requested action is illegal (e.g. ignoring _SSSS_IIII_GGGG_CCCC_OOOO_NNNN_TTTT, which
  83.                is ignored by default).
  84.  
  85.      [EINTR]   A signal was caught during the system call _ssss_iiii_gggg_pppp_aaaa_uuuu_ssss_eeee.
  86.  
  87. DDDDIIIIAAAAGGGGNNNNOOOOSSSSTTTTIIIICCCCSSSS
  88.      Upon successful completion, _ssss_iiii_gggg_ssss_eeee_tttt returns _SSSS_IIII_GGGG______HHHH_OOOO_LLLL_DDDD if the signal had
  89.      been blocked or the signal's previous disposition if it had not been
  90.      blocked.  Otherwise, a value of SSSSIIIIGGGG____EEEERRRRRRRR is returned and _e_r_r_n_o is set to
  91.      indicate the error.  SSSSIIIIGGGG____EEEERRRRRRRR is defined in <_s_y_s/_s_i_g_n_a_l._h>.
  92.  
  93.      For the other functions, upon successful completion, a value of 0 is
  94.      returned.  Otherwise, a value of -1 is returned and _e_r_r_n_o is set to
  95.      indicate the error.
  96.  
  97. SSSSEEEEEEEE AAAALLLLSSSSOOOO
  98.      csh(1), blockproc(2), kill(2), pause(2), setrlimit(2), sigaction(2),
  99.      signal(2), ulimit(2), wait(2), setjmp(3C), sigvec(3B), signal(5),
  100.      siginfo(5).
  101.  
  102. WWWWAAAARRRRNNNNIIIINNNNGGGGSSSS
  103.      Signals raised by the instruction stream, SSSSIIIIGGGGIIIILLLLLLLL, SSSSIIIIGGGGEEEEMMMMTTTT, SSSSIIIIGGGGBBBBUUUUSSSS, SSSSIIIIGGGGSSSSEEEEGGGGVVVV
  104.      will cause infinite loops if their handler returns, or the action is set
  105.      to SSSSIIIIGGGG____IIIIGGGGNNNN....
  106.  
  107.      The POSIX signal routines (_s_i_g_a_c_t_i_o_n(2), _s_i_g_p_e_n_d_i_n_g(2), _s_i_g_p_r_o_c_m_a_s_k(2),
  108.      _s_i_g_s_u_s_p_e_n_d(2), _s_i_g_s_e_t_j_m_p(3)), and the 4.3BSD signal routines (_s_i_g_v_e_c(3B),
  109.      _s_i_g_n_a_l(3B), _s_i_g_b_l_o_c_k(3B), _s_i_g_p_a_u_s_e(3B), _s_i_g_s_e_t_m_a_s_k(3B)) must NEVER be
  110.      used with _s_i_g_n_a_l(2) or _s_i_g_s_e_t(2).
  111.  
  112.  
  113.  
  114.  
  115.  
  116.  
  117.  
  118.  
  119.  
  120.  
  121.  
  122.  
  123.  
  124.  
  125.  
  126.  
  127.  
  128.  
  129.                                                                         PPPPaaaaggggeeee 2222
  130.  
  131.  
  132.  
  133.